<template>
    <div class="detail">
        <component :inputData="detailData" :is="currentComponent"></component>
    </div>

</template>

<script>
import detail from "commons/Detail";
import navMenu from "commons/NavMenu";
import baseMixin from "@/mixins/BaseMixin";

export default {
    name: "Detail",
    mixins: [baseMixin],
    data() {
        return {
            newFlag: true,
            selectData: {},
            detailData: {
                taskgroup: "",
                username: ""
            },
            detailNav: "1",
            temporary: {},
            componentConfig: [
                {
                    name: "GatherDetail",
                    label: "",
                    component: () => import('./page/particulars.vue')
                }
            ]
        }
    },
    computed: {
        currentComponent() {
            return this.componentConfig[this.detailNav - 1].component;
        }
    },
    methods: {},
    mounted() {
        //判断是否事新建
        if (Object.keys(this.$store.state.skip).length !== 0) {
            let data = this.$store.state.skip;
            this.detailData = data.detail;
        }

    },
    components: {
        "v-detail": detail,
        "v-navMenu": navMenu,
    },

}
</script>

<style scoped>

</style>
